function getStyle(obj,name){
	if(obj.currentStyle){
		return obj.currentStyle[name];
	}else{
		return getComputedStyle(obj,false)[name];
	}
}
/**
 * json 	{object}
 * json 	{name:value}
 * options	{object}
 * options	{duration:time,type:type,complete:function}
 */
function move(obj,json,options){
	var options = options || {};
	options.duration = options.duration || 500;
	options.type = options.type || 'easing-out';
	// 准备工作
	var count = Math.floor(options.duration/30);	//总次数
	var start = {};		//起点
	var dis = {};		//总距离=终点-起点
	for(var name in json){
		start[name] = parseInt(getStyle(obj,name));
		dis[name] = json[name] - start[name];
	}
	var n = 0;
	clearInterval(obj.timer);
	obj.timer = setInterval(function(){
		n++;
		for(var name in json){
			switch(options.type){
				case 'linear':
					var a = n/count;
					var cur = dis[name]*a;
					break;
				case 'easing-in':
					var a = n/count;
					var cur = dis[name]*(a*a*a);
					break;
				case 'easing-out':
					var a = 1-n/count;
					var cur = dis[name]*(1-a*a*a);
					break;
			}

			
			if(name == 'opacity'){
				obj.style.opacity = start[name]+cur;
				obj.style.filter = 'alpha(opacity:'+(start[name]+cur)*100+')';
			}else{
				obj.style[name] = start[name]+cur+'px';
			}
		}
		if(n == count){
			clearInterval(obj.timer);
			options.complete && options.complete();
		}
	},30);
}